/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * JFrameCliente.java
 *
 * Created on 29/10/2011, 11:07:35
 */
package visao;

import modelo.Animal;
import controle.AnimalDAO;
import controle.ClienteDAO;
import controle.EnderecoDAO;
import controle.EspecieDAO;
import controle.PessoaDAO;
import controle.RacaDAO;
import controle.TelefoneDAO;
import java.util.ArrayList;
import java.util.List;
import javax.swing.JOptionPane;
import javax.swing.JTable;
import javax.swing.table.DefaultTableModel;
import modelo.Cliente;
import modelo.Endereco;
import modelo.Especie;
import modelo.Raca;
import modelo.Telefone;

/**
 *
 * @author David
 */
public class JFrameCliente extends javax.swing.JFrame {

    /** Creates new form JFrameCliente */
    public JFrameCliente() {
        initComponents();
        this.redefinirTamanhoColunas();
        this.carregarCombos();
    }
    
    private void carregarCombos(){
    
        List<Especie> _le = new EspecieDAO().getEspecies(null);
        List<Raca> _lr = new RacaDAO().getRacas();
        
        for (Especie _e : _le){
            cmbEspecie.addItem(_e.getNome());
        }
        
        for (Raca _r : _lr){
            cmbRaca.addItem(_r.getNome());
        }
    }
    
    private void redefinirTamanhoColunas(){
    
        tbeResultadoCliente.getColumnModel().getColumn(0).setPreferredWidth(60); //codigo
        tbeResultadoCliente.getColumnModel().getColumn(1).setPreferredWidth(370);//nome
        tbeResultadoCliente.getColumnModel().getColumn(2).setPreferredWidth(160);//cpf
        tbeResultadoCliente.getColumnModel().getColumn(3).setPreferredWidth(160);//rg

        jTableAnimal.getColumnModel().getColumn(0).setPreferredWidth(60); //codigo
        jTableAnimal.getColumnModel().getColumn(1).setPreferredWidth(370);//nome
        jTableAnimal.getColumnModel().getColumn(2).setPreferredWidth(160);//especie
        jTableAnimal.getColumnModel().getColumn(3).setPreferredWidth(160);//raca   
        
        
    }
    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        pnlCliente = new javax.swing.JPanel();
        pnlBusca = new javax.swing.JPanel();
        jScrollPaneResultado = new javax.swing.JScrollPane();
        tbeResultadoCliente = new javax.swing.JTable();
        lblResultado = new javax.swing.JLabel();
        lblPesquisa = new javax.swing.JLabel();
        txtPesquisaCliente = new javax.swing.JTextField();
        btnBuscar = new javax.swing.JButton();
        pnlDados = new javax.swing.JPanel();
        lblCodigo = new javax.swing.JLabel();
        txtNome = new javax.swing.JTextField();
        lblNome = new javax.swing.JLabel();
        txtEmail = new javax.swing.JFormattedTextField();
        lblEmail = new javax.swing.JLabel();
        txtCpf = new javax.swing.JFormattedTextField();
        lblCpf = new javax.swing.JLabel();
        txtDtNascimento = new javax.swing.JFormattedTextField();
        lblDtNascimento = new javax.swing.JLabel();
        txtDtCadastro = new javax.swing.JFormattedTextField();
        pnlTelefone = new javax.swing.JPanel();
        jScrollPaneResultado1 = new javax.swing.JScrollPane();
        jTableTelefone = new javax.swing.JTable();
        pnlEndereço = new javax.swing.JPanel();
        txtEndereco = new javax.swing.JTextField();
        lblCidade = new javax.swing.JLabel();
        txtCidade = new javax.swing.JTextField();
        lblEstado = new javax.swing.JLabel();
        lblCep = new javax.swing.JLabel();
        txtCep = new javax.swing.JTextField();
        txtEstado = new javax.swing.JTextField();
        lblCpf1 = new javax.swing.JLabel();
        txtRg = new javax.swing.JFormattedTextField();
        jLabel1 = new javax.swing.JLabel();
        lblDtCadastro1 = new javax.swing.JLabel();
        txtCodigo = new javax.swing.JTextField();
        jLabel2 = new javax.swing.JLabel();
        jToolBarCliente = new javax.swing.JToolBar();
        jLabel13 = new javax.swing.JLabel();
        jButton5 = new javax.swing.JButton();
        jButton7 = new javax.swing.JButton();
        jButton8 = new javax.swing.JButton();
        pnlCadastroAnimal = new javax.swing.JPanel();
        pnlAnimal = new javax.swing.JPanel();
        lblPesquisarPor = new javax.swing.JLabel();
        txtPesquisaAnimal = new javax.swing.JTextField();
        btnBuscarAnimal = new javax.swing.JToggleButton();
        lblResulPesq = new javax.swing.JLabel();
        jScrollPaneAnimal = new javax.swing.JScrollPane();
        jTableAnimal = new javax.swing.JTable();
        jPanelDadosAnimal = new javax.swing.JPanel();
        lblNome1 = new javax.swing.JLabel();
        txtNomeAnimal = new javax.swing.JTextField();
        lblDataNasc = new javax.swing.JLabel();
        lblEspecie = new javax.swing.JLabel();
        cmbEspecie = new javax.swing.JComboBox();
        lblRaca = new javax.swing.JLabel();
        cmbRaca = new javax.swing.JComboBox();
        lblSexo = new javax.swing.JLabel();
        cmbSexo = new javax.swing.JComboBox();
        lblPorte = new javax.swing.JLabel();
        cmbPorte = new javax.swing.JComboBox();
        lblCodigo1 = new javax.swing.JLabel();
        txtCodigoAnimal = new javax.swing.JTextField();
        lblDataCadastroAnimal = new javax.swing.JLabel();
        txtDataNasciAnimal = new javax.swing.JTextField();
        txtDataCadastroAnimal = new javax.swing.JTextField();
        jLabel4 = new javax.swing.JLabel();
        jLabel19 = new javax.swing.JLabel();
        jLabel18 = new javax.swing.JLabel();
        tbrCliente = new javax.swing.JToolBar();
        btnNovo = new javax.swing.JButton();
        btnExcluir = new javax.swing.JButton();
        btnSalvar = new javax.swing.JButton();

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        setTitle("Cadastro de Cliente e Animal");
        setBounds(new java.awt.Rectangle(0, 0, 1100, 768));
        setMinimumSize(new java.awt.Dimension(1350, 768));
        setModalExclusionType(null);
        setResizable(false);
        getContentPane().setLayout(null);

        pnlCliente.setBorder(javax.swing.BorderFactory.createTitledBorder(new javax.swing.border.LineBorder(new java.awt.Color(51, 51, 51), 1, true), "Cliente", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Verdana", 1, 12), new java.awt.Color(51, 51, 51))); // NOI18N

        pnlBusca.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)), "Busca", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Verdana", 1, 12), new java.awt.Color(51, 51, 51))); // NOI18N

        tbeResultadoCliente.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)));
        tbeResultadoCliente.setFont(new java.awt.Font("Verdana", 0, 12)); // NOI18N
        tbeResultadoCliente.setForeground(new java.awt.Color(51, 51, 51));
        tbeResultadoCliente.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null}
            },
            new String [] {
                "Código", "Nome", "CPF", "RG "
            }
        ) {
            Class[] types = new Class [] {
                java.lang.Integer.class, java.lang.String.class, java.lang.String.class, java.lang.String.class
            };
            boolean[] canEdit = new boolean [] {
                false, false, false, false
            };

            public Class getColumnClass(int columnIndex) {
                return types [columnIndex];
            }

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        tbeResultadoCliente.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseReleased(java.awt.event.MouseEvent evt) {
                tbeResultadoClienteMouseReleased(evt);
            }
        });
        jScrollPaneResultado.setViewportView(tbeResultadoCliente);

        lblResultado.setFont(new java.awt.Font("Verdana", 0, 12));
        lblResultado.setForeground(new java.awt.Color(51, 51, 51));
        lblResultado.setText("Resultado da Pesquisa:");

        lblPesquisa.setFont(new java.awt.Font("Verdana", 0, 12));
        lblPesquisa.setForeground(new java.awt.Color(51, 51, 51));
        lblPesquisa.setText("Pesquisar por nome:");

        txtPesquisaCliente.setFont(new java.awt.Font("Verdana", 0, 12));
        txtPesquisaCliente.setForeground(new java.awt.Color(51, 51, 51));
        txtPesquisaCliente.setToolTipText("");

        btnBuscar.setFont(new java.awt.Font("Verdana", 0, 12));
        btnBuscar.setForeground(new java.awt.Color(51, 51, 51));
        btnBuscar.setText("Buscar");
        btnBuscar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnBuscarActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout pnlBuscaLayout = new javax.swing.GroupLayout(pnlBusca);
        pnlBusca.setLayout(pnlBuscaLayout);
        pnlBuscaLayout.setHorizontalGroup(
            pnlBuscaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlBuscaLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(pnlBuscaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jScrollPaneResultado, javax.swing.GroupLayout.DEFAULT_SIZE, 625, Short.MAX_VALUE)
                    .addComponent(lblResultado)
                    .addGroup(pnlBuscaLayout.createSequentialGroup()
                        .addComponent(lblPesquisa)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(txtPesquisaCliente, javax.swing.GroupLayout.DEFAULT_SIZE, 389, Short.MAX_VALUE)
                        .addGap(18, 18, 18)
                        .addComponent(btnBuscar)))
                .addContainerGap())
        );
        pnlBuscaLayout.setVerticalGroup(
            pnlBuscaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlBuscaLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(pnlBuscaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(lblPesquisa)
                    .addGroup(pnlBuscaLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                        .addComponent(txtPesquisaCliente, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(btnBuscar)))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(lblResultado)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPaneResultado, javax.swing.GroupLayout.DEFAULT_SIZE, 131, Short.MAX_VALUE)
                .addContainerGap())
        );

        pnlDados.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)), "Dados do Cliente", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Verdana", 1, 12), new java.awt.Color(51, 51, 51))); // NOI18N

        lblCodigo.setFont(new java.awt.Font("Verdana", 0, 12));
        lblCodigo.setForeground(new java.awt.Color(51, 51, 51));
        lblCodigo.setText("Código:");

        txtNome.setFont(new java.awt.Font("Verdana", 0, 12));
        txtNome.setForeground(new java.awt.Color(51, 51, 51));
        txtNome.setToolTipText("");

        lblNome.setFont(new java.awt.Font("Verdana", 0, 12));
        lblNome.setForeground(new java.awt.Color(51, 51, 51));
        lblNome.setText("Nome:");

        txtEmail.setForeground(new java.awt.Color(51, 51, 51));

        lblEmail.setFont(new java.awt.Font("Verdana", 0, 12));
        lblEmail.setForeground(new java.awt.Color(51, 51, 51));
        lblEmail.setText("Email");

        txtCpf.setForeground(new java.awt.Color(51, 51, 51));

        lblCpf.setFont(new java.awt.Font("Verdana", 0, 12));
        lblCpf.setForeground(new java.awt.Color(51, 51, 51));
        lblCpf.setText("CPF");

        txtDtNascimento.setForeground(new java.awt.Color(51, 51, 51));

        lblDtNascimento.setFont(new java.awt.Font("Verdana", 0, 12));
        lblDtNascimento.setForeground(new java.awt.Color(51, 51, 51));
        lblDtNascimento.setText("Data de Nasc");

        txtDtCadastro.setEditable(false);
        txtDtCadastro.setForeground(new java.awt.Color(51, 51, 51));

        pnlTelefone.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)), "Telefones", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Verdana", 0, 12))); // NOI18N

        jTableTelefone.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)));
        jTableTelefone.setFont(new java.awt.Font("Verdana", 0, 12)); // NOI18N
        jTableTelefone.setForeground(new java.awt.Color(51, 51, 51));
        jTableTelefone.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {
                {"Residencial", null},
                {"Celular", null},
                {"Recado", null},
                {"Comercial", null}
            },
            new String [] {
                "Tipo", "Telefone"
            }
        ) {
            Class[] types = new Class [] {
                java.lang.String.class, java.lang.String.class
            };
            boolean[] canEdit = new boolean [] {
                false, true
            };

            public Class getColumnClass(int columnIndex) {
                return types [columnIndex];
            }

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        jTableTelefone.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseReleased(java.awt.event.MouseEvent evt) {
                jTableTelefoneMouseReleased(evt);
            }
        });
        jScrollPaneResultado1.setViewportView(jTableTelefone);

        javax.swing.GroupLayout pnlTelefoneLayout = new javax.swing.GroupLayout(pnlTelefone);
        pnlTelefone.setLayout(pnlTelefoneLayout);
        pnlTelefoneLayout.setHorizontalGroup(
            pnlTelefoneLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlTelefoneLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jScrollPaneResultado1, javax.swing.GroupLayout.DEFAULT_SIZE, 196, Short.MAX_VALUE)
                .addContainerGap())
        );
        pnlTelefoneLayout.setVerticalGroup(
            pnlTelefoneLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlTelefoneLayout.createSequentialGroup()
                .addComponent(jScrollPaneResultado1, javax.swing.GroupLayout.DEFAULT_SIZE, 151, Short.MAX_VALUE)
                .addContainerGap())
        );

        pnlEndereço.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)), "Endereço", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Verdana", 0, 12))); // NOI18N

        txtEndereco.setFont(new java.awt.Font("Verdana", 0, 12));
        txtEndereco.setForeground(new java.awt.Color(51, 51, 51));

        lblCidade.setFont(new java.awt.Font("Verdana", 0, 12));
        lblCidade.setForeground(new java.awt.Color(51, 51, 51));
        lblCidade.setText("Cidade");

        txtCidade.setFont(new java.awt.Font("Verdana", 0, 12));
        txtCidade.setForeground(new java.awt.Color(51, 51, 51));

        lblEstado.setFont(new java.awt.Font("Verdana", 0, 12));
        lblEstado.setForeground(new java.awt.Color(51, 51, 51));
        lblEstado.setText("Estado");

        lblCep.setFont(new java.awt.Font("Verdana", 0, 12));
        lblCep.setForeground(new java.awt.Color(51, 51, 51));
        lblCep.setText("CEP");

        txtCep.setFont(new java.awt.Font("Verdana", 0, 12));
        txtCep.setForeground(new java.awt.Color(51, 51, 51));

        txtEstado.setFont(new java.awt.Font("Verdana", 0, 12));
        txtEstado.setForeground(new java.awt.Color(51, 51, 51));

        javax.swing.GroupLayout pnlEndereçoLayout = new javax.swing.GroupLayout(pnlEndereço);
        pnlEndereço.setLayout(pnlEndereçoLayout);
        pnlEndereçoLayout.setHorizontalGroup(
            pnlEndereçoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlEndereçoLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(pnlEndereçoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(txtEndereco, javax.swing.GroupLayout.DEFAULT_SIZE, 365, Short.MAX_VALUE)
                    .addGroup(pnlEndereçoLayout.createSequentialGroup()
                        .addGroup(pnlEndereçoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(lblCidade)
                            .addComponent(lblEstado))
                        .addGap(13, 13, 13)
                        .addGroup(pnlEndereçoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(txtCidade, javax.swing.GroupLayout.DEFAULT_SIZE, 308, Short.MAX_VALUE)
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, pnlEndereçoLayout.createSequentialGroup()
                                .addComponent(txtEstado, javax.swing.GroupLayout.PREFERRED_SIZE, 53, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 87, Short.MAX_VALUE)
                                .addComponent(lblCep)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                .addComponent(txtCep, javax.swing.GroupLayout.PREFERRED_SIZE, 133, javax.swing.GroupLayout.PREFERRED_SIZE)))))
                .addContainerGap())
        );
        pnlEndereçoLayout.setVerticalGroup(
            pnlEndereçoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, pnlEndereçoLayout.createSequentialGroup()
                .addComponent(txtEndereco, javax.swing.GroupLayout.PREFERRED_SIZE, 49, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(pnlEndereçoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(txtCidade, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblCidade))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(pnlEndereçoLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(lblEstado)
                    .addComponent(txtCep, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblCep)
                    .addComponent(txtEstado, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(52, Short.MAX_VALUE))
        );

        lblCpf1.setFont(new java.awt.Font("Verdana", 0, 12));
        lblCpf1.setForeground(new java.awt.Color(51, 51, 51));
        lblCpf1.setText("RG");

        txtRg.setForeground(new java.awt.Color(51, 51, 51));

        jLabel1.setForeground(new java.awt.Color(255, 0, 0));
        jLabel1.setText("O formato da data deve ser YYYY-MM-DD");

        lblDtCadastro1.setFont(new java.awt.Font("Verdana", 0, 12));
        lblDtCadastro1.setForeground(new java.awt.Color(51, 51, 51));
        lblDtCadastro1.setText("Data de Cadastro:");

        txtCodigo.setEditable(false);
        txtCodigo.setFont(new java.awt.Font("Verdana", 0, 12));
        txtCodigo.setForeground(new java.awt.Color(51, 51, 51));

        jLabel2.setForeground(new java.awt.Color(255, 0, 51));
        jLabel2.setText("Exemplo: 2008-02-28");

        javax.swing.GroupLayout pnlDadosLayout = new javax.swing.GroupLayout(pnlDados);
        pnlDados.setLayout(pnlDadosLayout);
        pnlDadosLayout.setHorizontalGroup(
            pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlDadosLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(pnlDadosLayout.createSequentialGroup()
                        .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(pnlDadosLayout.createSequentialGroup()
                                .addComponent(pnlTelefone, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(pnlEndereço, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                            .addGroup(pnlDadosLayout.createSequentialGroup()
                                .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addComponent(lblEmail)
                                    .addComponent(lblNome)
                                    .addComponent(lblCpf))
                                .addGap(105, 105, 105)
                                .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addComponent(txtEmail, javax.swing.GroupLayout.DEFAULT_SIZE, 481, Short.MAX_VALUE)
                                    .addGroup(pnlDadosLayout.createSequentialGroup()
                                        .addComponent(txtCpf, javax.swing.GroupLayout.PREFERRED_SIZE, 179, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addGap(18, 18, 18)
                                        .addComponent(lblCpf1)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 88, Short.MAX_VALUE)
                                        .addComponent(txtRg, javax.swing.GroupLayout.PREFERRED_SIZE, 179, javax.swing.GroupLayout.PREFERRED_SIZE))
                                    .addComponent(txtCodigo, javax.swing.GroupLayout.DEFAULT_SIZE, 481, Short.MAX_VALUE)
                                    .addComponent(txtNome, javax.swing.GroupLayout.DEFAULT_SIZE, 481, Short.MAX_VALUE))))
                        .addContainerGap())
                    .addComponent(lblCodigo)
                    .addGroup(pnlDadosLayout.createSequentialGroup()
                        .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(lblDtNascimento)
                            .addComponent(lblDtCadastro1))
                        .addGap(29, 29, 29)
                        .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(txtDtCadastro, javax.swing.GroupLayout.DEFAULT_SIZE, 264, Short.MAX_VALUE)
                            .addComponent(txtDtNascimento, javax.swing.GroupLayout.DEFAULT_SIZE, 264, Short.MAX_VALUE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(jLabel2)
                            .addComponent(jLabel1))
                        .addGap(18, 18, 18))))
        );
        pnlDadosLayout.setVerticalGroup(
            pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlDadosLayout.createSequentialGroup()
                .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(lblNome)
                    .addComponent(txtNome, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(txtEmail, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblEmail))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(txtCpf, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblCpf1)
                    .addComponent(txtRg, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblCpf))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(lblCodigo)
                    .addComponent(txtCodigo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(txtDtNascimento, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblDtNascimento)
                    .addComponent(jLabel1))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(txtDtCadastro, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(lblDtCadastro1)
                    .addComponent(jLabel2))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(pnlDadosLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(pnlTelefone, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(pnlEndereço, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );

        javax.swing.GroupLayout pnlClienteLayout = new javax.swing.GroupLayout(pnlCliente);
        pnlCliente.setLayout(pnlClienteLayout);
        pnlClienteLayout.setHorizontalGroup(
            pnlClienteLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlClienteLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(pnlClienteLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(pnlDados, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(pnlBusca, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap())
        );
        pnlClienteLayout.setVerticalGroup(
            pnlClienteLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlClienteLayout.createSequentialGroup()
                .addComponent(pnlBusca, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(pnlDados, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addContainerGap())
        );

        getContentPane().add(pnlCliente);
        pnlCliente.setBounds(10, 48, 687, 680);

        jToolBarCliente.setBorder(javax.swing.BorderFactory.createEtchedBorder());
        jToolBarCliente.setRollover(true);
        jToolBarCliente.setToolTipText("Sair");
        jToolBarCliente.add(jLabel13);

        jButton5.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/page.png"))); // NOI18N
        jButton5.setToolTipText("Novo");
        jButton5.setFocusable(false);
        jButton5.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        jButton5.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        jButton5.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton5ActionPerformed(evt);
            }
        });
        jToolBarCliente.add(jButton5);

        jButton7.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/bin_closed.png"))); // NOI18N
        jButton7.setToolTipText("Editar");
        jButton7.setFocusable(false);
        jButton7.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        jButton7.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        jToolBarCliente.add(jButton7);

        jButton8.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/disk.png"))); // NOI18N
        jButton8.setToolTipText("Excluir");
        jButton8.setFocusable(false);
        jButton8.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        jButton8.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        jButton8.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton8ActionPerformed(evt);
            }
        });
        jToolBarCliente.add(jButton8);

        getContentPane().add(jToolBarCliente);
        jToolBarCliente.setBounds(707, 11, 91, 31);

        pnlCadastroAnimal.setBorder(javax.swing.BorderFactory.createTitledBorder(new javax.swing.border.LineBorder(new java.awt.Color(51, 51, 51), 1, true), "Animal", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Verdana", 1, 12), new java.awt.Color(51, 51, 51))); // NOI18N
        pnlCadastroAnimal.setForeground(new java.awt.Color(51, 51, 51));
        pnlCadastroAnimal.setFont(new java.awt.Font("Verdana", 1, 12)); // NOI18N
        pnlCadastroAnimal.setLayout(null);

        pnlAnimal.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)), "Busca", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Verdana", 1, 12), new java.awt.Color(51, 51, 51))); // NOI18N

        lblPesquisarPor.setFont(new java.awt.Font("Verdana", 0, 12));
        lblPesquisarPor.setForeground(new java.awt.Color(51, 51, 51));
        lblPesquisarPor.setText("Pesquisar por nome:");

        txtPesquisaAnimal.setFont(new java.awt.Font("Tahoma", 0, 12));
        txtPesquisaAnimal.setForeground(new java.awt.Color(51, 51, 51));
        txtPesquisaAnimal.setToolTipText("");

        btnBuscarAnimal.setFont(new java.awt.Font("Verdana", 0, 12));
        btnBuscarAnimal.setForeground(new java.awt.Color(51, 51, 51));
        btnBuscarAnimal.setText("Buscar");
        btnBuscarAnimal.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnBuscarAnimalActionPerformed(evt);
            }
        });

        lblResulPesq.setFont(new java.awt.Font("Verdana", 0, 12));
        lblResulPesq.setForeground(new java.awt.Color(51, 51, 51));
        lblResulPesq.setText("Resultado da Pesquisa:");

        jTableAnimal.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)));
        jTableAnimal.setFont(new java.awt.Font("Verdana", 0, 12)); // NOI18N
        jTableAnimal.setForeground(new java.awt.Color(51, 51, 51));
        jTableAnimal.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null},
                {null, null, null, null}
            },
            new String [] {
                "Código", "Nome", "Especie", "Raca"
            }
        ) {
            Class[] types = new Class [] {
                java.lang.Integer.class, java.lang.String.class, java.lang.String.class, java.lang.String.class
            };

            public Class getColumnClass(int columnIndex) {
                return types [columnIndex];
            }
        });
        jTableAnimal.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseReleased(java.awt.event.MouseEvent evt) {
                jTableAnimalMouseReleased(evt);
            }
        });
        jScrollPaneAnimal.setViewportView(jTableAnimal);

        javax.swing.GroupLayout pnlAnimalLayout = new javax.swing.GroupLayout(pnlAnimal);
        pnlAnimal.setLayout(pnlAnimalLayout);
        pnlAnimalLayout.setHorizontalGroup(
            pnlAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlAnimalLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(pnlAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(lblResulPesq)
                    .addGroup(pnlAnimalLayout.createSequentialGroup()
                        .addComponent(lblPesquisarPor)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(txtPesquisaAnimal, javax.swing.GroupLayout.PREFERRED_SIZE, 341, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(btnBuscarAnimal))
                    .addComponent(jScrollPaneAnimal, javax.swing.GroupLayout.PREFERRED_SIZE, 481, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        pnlAnimalLayout.setVerticalGroup(
            pnlAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(pnlAnimalLayout.createSequentialGroup()
                .addGroup(pnlAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(lblPesquisarPor)
                    .addComponent(txtPesquisaAnimal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(btnBuscarAnimal))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(lblResulPesq)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jScrollPaneAnimal, javax.swing.GroupLayout.DEFAULT_SIZE, 134, Short.MAX_VALUE)
                .addContainerGap())
        );

        pnlCadastroAnimal.add(pnlAnimal);
        pnlAnimal.setBounds(15, 21, 515, 234);

        jPanelDadosAnimal.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0)), "Dados do Animal", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Verdana", 1, 12), new java.awt.Color(51, 51, 51))); // NOI18N
        jPanelDadosAnimal.setFont(new java.awt.Font("Verdana", 0, 12));

        lblNome1.setFont(new java.awt.Font("Verdana", 0, 12));
        lblNome1.setForeground(new java.awt.Color(51, 51, 51));
        lblNome1.setText("Nome:");

        txtNomeAnimal.setFont(new java.awt.Font("Verdana", 0, 12));
        txtNomeAnimal.setForeground(new java.awt.Color(51, 51, 51));
        txtNomeAnimal.setToolTipText("");

        lblDataNasc.setFont(new java.awt.Font("Verdana", 0, 12));
        lblDataNasc.setForeground(new java.awt.Color(51, 51, 51));
        lblDataNasc.setText("Data de Nascimento:");

        lblEspecie.setFont(new java.awt.Font("Verdana", 0, 12));
        lblEspecie.setForeground(new java.awt.Color(51, 51, 51));
        lblEspecie.setText("Espécie:");

        cmbEspecie.setEditable(true);
        cmbEspecie.setFont(new java.awt.Font("Verdana", 0, 12));
        cmbEspecie.setForeground(new java.awt.Color(51, 51, 51));

        lblRaca.setFont(new java.awt.Font("Verdana", 0, 12));
        lblRaca.setForeground(new java.awt.Color(51, 51, 51));
        lblRaca.setText("Raça:");

        cmbRaca.setEditable(true);
        cmbRaca.setFont(new java.awt.Font("Verdana", 0, 12));
        cmbRaca.setForeground(new java.awt.Color(51, 51, 51));

        lblSexo.setFont(new java.awt.Font("Verdana", 0, 12));
        lblSexo.setForeground(new java.awt.Color(51, 51, 51));
        lblSexo.setText("Sexo:");

        cmbSexo.setEditable(true);
        cmbSexo.setFont(new java.awt.Font("Verdana", 0, 12));
        cmbSexo.setForeground(new java.awt.Color(51, 51, 51));
        cmbSexo.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Macho", "Fêmea" }));

        lblPorte.setFont(new java.awt.Font("Verdana", 0, 12));
        lblPorte.setForeground(new java.awt.Color(51, 51, 51));
        lblPorte.setText("Porte:");

        cmbPorte.setEditable(true);
        cmbPorte.setFont(new java.awt.Font("Verdana", 0, 12));
        cmbPorte.setForeground(new java.awt.Color(51, 51, 51));
        cmbPorte.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Pequeno", "Medio", "Grande" }));

        lblCodigo1.setFont(new java.awt.Font("Verdana", 0, 12));
        lblCodigo1.setForeground(new java.awt.Color(51, 51, 51));
        lblCodigo1.setText("Código:");

        txtCodigoAnimal.setEditable(false);
        txtCodigoAnimal.setFont(new java.awt.Font("Verdana", 0, 12));
        txtCodigoAnimal.setForeground(new java.awt.Color(51, 51, 51));

        lblDataCadastroAnimal.setFont(new java.awt.Font("Verdana", 0, 12));
        lblDataCadastroAnimal.setForeground(new java.awt.Color(51, 51, 51));
        lblDataCadastroAnimal.setText("Dt Cadastro:");

        txtDataNasciAnimal.setFont(new java.awt.Font("Verdana", 0, 12));
        txtDataNasciAnimal.setForeground(new java.awt.Color(51, 51, 51));
        txtDataNasciAnimal.setToolTipText("");

        txtDataCadastroAnimal.setEditable(false);
        txtDataCadastroAnimal.setFont(new java.awt.Font("Verdana", 0, 12));
        txtDataCadastroAnimal.setForeground(new java.awt.Color(51, 51, 51));
        txtDataCadastroAnimal.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                txtDataCadastroAnimalActionPerformed(evt);
            }
        });

        jLabel4.setForeground(new java.awt.Color(255, 0, 51));
        jLabel4.setText("Exemplo: 2008-02-28");

        javax.swing.GroupLayout jPanelDadosAnimalLayout = new javax.swing.GroupLayout(jPanelDadosAnimal);
        jPanelDadosAnimal.setLayout(jPanelDadosAnimalLayout);
        jPanelDadosAnimalLayout.setHorizontalGroup(
            jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(lblSexo)
                    .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                        .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                                .addComponent(lblEspecie)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 431, Short.MAX_VALUE))
                            .addComponent(lblCodigo1)
                            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanelDadosAnimalLayout.createSequentialGroup()
                                .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, jPanelDadosAnimalLayout.createSequentialGroup()
                                        .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                            .addComponent(lblNome1)
                                            .addComponent(lblDataNasc))
                                        .addGap(33, 33, 33))
                                    .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                                        .addComponent(lblDataCadastroAnimal, javax.swing.GroupLayout.PREFERRED_SIZE, 133, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addGap(32, 32, 32)))
                                .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                    .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                                        .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                                            .addComponent(txtDataCadastroAnimal, javax.swing.GroupLayout.Alignment.LEADING)
                                            .addComponent(txtCodigoAnimal, javax.swing.GroupLayout.Alignment.LEADING)
                                            .addComponent(cmbSexo, javax.swing.GroupLayout.Alignment.LEADING, 0, 0, Short.MAX_VALUE)
                                            .addComponent(cmbEspecie, javax.swing.GroupLayout.Alignment.LEADING, 0, 0, Short.MAX_VALUE)
                                            .addComponent(txtDataNasciAnimal, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, 111, Short.MAX_VALUE))
                                        .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                            .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                                                .addGap(14, 14, 14)
                                                .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                                    .addComponent(lblRaca)
                                                    .addComponent(lblPorte))
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                                .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                                    .addComponent(cmbPorte, 0, 0, Short.MAX_VALUE)
                                                    .addComponent(cmbRaca, 0, 0, Short.MAX_VALUE)))
                                            .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                                .addComponent(jLabel4, javax.swing.GroupLayout.PREFERRED_SIZE, 198, javax.swing.GroupLayout.PREFERRED_SIZE))))
                                    .addComponent(txtNomeAnimal, javax.swing.GroupLayout.DEFAULT_SIZE, 319, Short.MAX_VALUE))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)))
                        .addGap(214, 214, 214)))
                .addContainerGap())
        );
        jPanelDadosAnimalLayout.setVerticalGroup(
            jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                        .addComponent(txtNomeAnimal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(txtDataNasciAnimal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(jLabel4)))
                    .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                        .addComponent(lblNome1)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(lblDataNasc)))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                        .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(lblEspecie)
                            .addComponent(cmbEspecie, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(lblSexo)
                            .addComponent(cmbSexo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                    .addGroup(jPanelDadosAnimalLayout.createSequentialGroup()
                        .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(lblRaca)
                            .addComponent(cmbRaca, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(lblPorte)
                            .addComponent(cmbPorte, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))))
                .addGap(18, 18, 18)
                .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(lblCodigo1)
                    .addComponent(txtCodigoAnimal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(jPanelDadosAnimalLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(lblDataCadastroAnimal)
                    .addComponent(txtDataCadastroAnimal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(53, Short.MAX_VALUE))
        );

        pnlCadastroAnimal.add(jPanelDadosAnimal);
        jPanelDadosAnimal.setBounds(15, 266, 515, 288);

        getContentPane().add(pnlCadastroAnimal);
        pnlCadastroAnimal.setBounds(707, 48, 540, 680);

        jLabel19.setFont(new java.awt.Font("Verdana", 0, 18));
        jLabel19.setForeground(new java.awt.Color(102, 102, 255));
        jLabel19.setText("Cadastro de Animais");
        jLabel19.setName("lblCadastroAnimal"); // NOI18N
        getContentPane().add(jLabel19);
        jLabel19.setBounds(802, 11, 186, 23);

        jLabel18.setFont(new java.awt.Font("Verdana", 0, 18));
        jLabel18.setForeground(new java.awt.Color(102, 102, 255));
        jLabel18.setText("Cadastro de Clientes");
        jLabel18.setName("lblCadastroAnimal"); // NOI18N
        getContentPane().add(jLabel18);
        jLabel18.setBounds(111, 11, 187, 23);

        tbrCliente.setBorder(javax.swing.BorderFactory.createEtchedBorder());
        tbrCliente.setRollover(true);
        tbrCliente.setToolTipText("Sair");

        btnNovo.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/page.png"))); // NOI18N
        btnNovo.setToolTipText("Novo");
        btnNovo.setFocusable(false);
        btnNovo.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        btnNovo.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        btnNovo.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnNovoActionPerformed(evt);
            }
        });
        tbrCliente.add(btnNovo);

        btnExcluir.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/bin_closed.png"))); // NOI18N
        btnExcluir.setToolTipText("Excluir");
        btnExcluir.setFocusable(false);
        btnExcluir.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        btnExcluir.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        tbrCliente.add(btnExcluir);

        btnSalvar.setIcon(new javax.swing.ImageIcon(getClass().getResource("/images/disk.png"))); // NOI18N
        btnSalvar.setToolTipText("Salvar");
        btnSalvar.setFocusable(false);
        btnSalvar.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
        btnSalvar.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
        btnSalvar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnSalvarActionPerformed(evt);
            }
        });
        tbrCliente.add(btnSalvar);

        getContentPane().add(tbrCliente);
        tbrCliente.setBounds(10, 11, 91, 31);

        pack();
    }// </editor-fold>//GEN-END:initComponents

private void btnNovoActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnNovoActionPerformed

        
        txtCodigo.setText("*");    
        txtCodigoAnimal.setText("*");
        
        txtNome.setText(null);
        txtCpf.setText(null);
        txtEmail.setText(null);
        
        txtRg.setText(null);
        txtDtCadastro.setText(null);
        txtDtNascimento.setText(null);
        
        txtEndereco.setText(null);
        txtCep.setText(null);
        txtCidade.setText(null);
        txtEstado.setText(null);
        
        txtNomeAnimal.setText(null);
        txtDataNasciAnimal.setText(null);
        txtDataCadastroAnimal.setText(null);
        
        //posiciona a porte
        cmbPorte.setSelectedIndex(0);
        cmbEspecie.setSelectedIndex(0);
        cmbRaca.setSelectedIndex(0);
        cmbSexo.setSelectedIndex(0);
        
        this.limparResutladosBuscas(jTableAnimal);
        this.limparResutladosBuscas(tbeResultadoCliente);  
        
        txtNome.requestFocus();        
            
}//GEN-LAST:event_btnNovoActionPerformed

    private void limparResutladosBuscas(JTable ojt){
        DefaultTableModel tbm = (DefaultTableModel)ojt.getModel();
        for(int i = tbm.getRowCount()-1; i >= 0; i--){
            tbm.removeRow(i);
        }
    }

    private void btnBuscarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnBuscarActionPerformed
        
        ClienteDAO _cDAO = new ClienteDAO();
        List<Cliente> _lc = _cDAO.getClientes("UPPER(P.NOME) LIKE UPPER('%" + txtPesquisaCliente.getText() + "%')");

        DefaultTableModel tbm = (DefaultTableModel)tbeResultadoCliente.getModel();
        
        //limpa o resultado
        for(int i = tbm.getRowCount()-1; i >= 0; i--){
            tbm.removeRow(i);
        }
                
        int i = 0;
        for (Cliente _c : _lc){
        
            tbm.addRow(new String[1]);
            tbeResultadoCliente.setValueAt(_c.getCodigoPessoa(), i, 0);
            tbeResultadoCliente.setValueAt(_c.getNome(), i, 1);
            tbeResultadoCliente.setValueAt(_c.getCpf(), i, 2);
            tbeResultadoCliente.setValueAt(_c.getRg(), i, 3);
            i++;
        }
        
    }//GEN-LAST:event_btnBuscarActionPerformed

    private void tbeResultadoClienteMouseReleased(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_tbeResultadoClienteMouseReleased

        int iLinha = tbeResultadoCliente.getSelectedRow();     
        String sCodigo = tbeResultadoCliente.getValueAt(iLinha, 0).toString();
        int codigoPessoa = Integer.parseInt(sCodigo);
        Cliente _c = new ClienteDAO().getClienteByCodigo(codigoPessoa);
        
        txtNome.setText(_c.getNome());
        txtCpf.setText(_c.getCpf());
        txtEmail.setText(_c.getEmail());
        txtCodigo.setText(String.valueOf(_c.getCodigoPessoa()));
        txtRg.setText(_c.getRg());
        txtDtCadastro.setText(_c.getDataCadastro());
        txtDtNascimento.setText(_c.getDataNascimento());
        
        txtEndereco.setText(_c.getEndereco().getEndereco());
        txtCep.setText(_c.getEndereco().getCEP());
        txtCidade.setText(_c.getEndereco().getCidade());
        txtEstado.setText(_c.getEndereco().getEstado());
        
        //lista os telefones
        for(int i = 0 ; i <= jTableTelefone.getRowCount()-1; i++){
            jTableTelefone.setValueAt("", i, 1);
        }
        for(Telefone _t : _c.getTelefone()){
            for (int l = 0; l <= jTableTelefone.getRowCount()-1; l++){
                if (jTableTelefone.getValueAt(l, 0).toString().equals(_t.getTipo())){
                    jTableTelefone.setValueAt(_t.getNumero(), l, 1);
                }            
            }        
        }       
        
        //exibe os animais
        List<Animal> _la = new AnimalDAO().getAnimaisByCodigoCliente(codigoPessoa);
        DefaultTableModel tbm = (DefaultTableModel)jTableAnimal.getModel();        
        
        for(int i = tbm.getRowCount()-1; i >= 0; i--){
            tbm.removeRow(i);
        }
                
        int i = 0;
        for (Animal _a : _la){
        
            tbm.addRow(new String[1]);
            tbm.setValueAt(_a.getCodigoAnimal(), i, 0);
            tbm.setValueAt(_a.getNomeAnimal(), i, 1);
            tbm.setValueAt(_a.getEspecie().getNome(), i, 2);
            tbm.setValueAt(_a.getRaca().getNome(), i, 3);
            
            i++;
        }        
        
    }//GEN-LAST:event_tbeResultadoClienteMouseReleased

    private void jTableTelefoneMouseReleased(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jTableTelefoneMouseReleased
        // TODO add your handling code here:
    }//GEN-LAST:event_jTableTelefoneMouseReleased

    private void btnSalvarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnSalvarActionPerformed
        
        Cliente _c = new Cliente();
        
        _c.setNome(txtNome.getText());
        _c.setCpf(txtCpf.getText());
        _c.setRg(txtRg.getText());
        _c.setDataNascimento(txtDtNascimento.getText());
        _c.setEmail(txtEmail.getText());
                
        if (txtCodigo.getText().equals("*")){
            _c.setCodigoPessoa(0);
        } else {
            _c.setCodigoPessoa(Integer.parseInt(txtCodigo.getText()));
        }
        
        Endereco _e = new Endereco();
        _e.setEndereco(txtEndereco.getText());
        _e.setCEP(txtCep.getText());
        _e.setCidade(txtCidade.getText());
        _e.setEstado(txtEstado.getText());        
        _e.setCodigoEndereco(EnderecoDAO.getCodigoProximo());
        
        _c.setEndereco(_e);
        
        List<Telefone> _lt = new ArrayList<Telefone>();

        DefaultTableModel tbm = (DefaultTableModel)jTableTelefone.getModel();
        
        //limpa o resultado
        for(int i = 0; i <= tbm.getRowCount()-1; i++)
        {
            String valor = (String) jTableTelefone.getValueAt(i, 1);
            if (valor != null){
                Telefone _t = new Telefone();
                _t.setNumero(tbm.getValueAt(i, 1).toString());
                _t.setTipo(tbm.getValueAt(i, 0).toString());
                _t.setCodigoTelefone(TelefoneDAO.getCodigoProximo());
                
                _lt.add(_t);
            }
        }
        
        _c.setTelefone(_lt);
        
        ClienteDAO _cDAO = new ClienteDAO();
        boolean ret = _cDAO.salvarCliente(_c);
        
        if (ret){
            JOptionPane.showMessageDialog(null, "Animal incluído com sucesso.");
        } else {
            JOptionPane.showMessageDialog(null, "Erro ao inserir o animal.");
        }
        
        
    }//GEN-LAST:event_btnSalvarActionPerformed

    private void btnBuscarAnimalActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnBuscarAnimalActionPerformed
        
        
    }//GEN-LAST:event_btnBuscarAnimalActionPerformed

    private void txtDataCadastroAnimalActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_txtDataCadastroAnimalActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_txtDataCadastroAnimalActionPerformed

    private void jTableAnimalMouseReleased(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_jTableAnimalMouseReleased

        int iLinha = jTableAnimal.getSelectedRow();     
        String sCodigo = jTableAnimal.getValueAt(iLinha, 0).toString();
        int codigoAnimal = Integer.parseInt(sCodigo);
        Animal _a = new AnimalDAO().getAnimaisByCodigoAnimal(codigoAnimal);
        
        txtNomeAnimal.setText(_a.getNomeAnimal());
        txtDataNasciAnimal.setText(_a.getDataNasc());
        txtCodigoAnimal.setText(String.valueOf(_a.getCodigoAnimal()));
        txtDataCadastroAnimal.setText(_a.getDataCadastro());
        
        //posiciona a especie cadastrada
        for (int x = 0; x <= cmbEspecie.getItemCount() -1; x++){
            if (cmbEspecie.getItemAt(x).toString().equals(_a.getEspecie().getNome())){
                cmbEspecie.setSelectedIndex(x);                
            }
        }

        //posiciona a raca
        for (int x = 0; x <= cmbRaca.getItemCount() -1; x++){
            if (cmbRaca.getItemAt(x).toString().equals(_a.getRaca().getNome())){
                cmbRaca.setSelectedIndex(x);                
            }
        }

        //posiciona a sexo
        for (int x = 0; x <= cmbSexo.getItemCount() -1; x++){
            if (cmbSexo.getItemAt(x).toString().equals(_a.getSexo())){
                cmbSexo.setSelectedIndex(x);                
            }
        }

        //posiciona a porte
        for (int x = 0; x <= cmbPorte.getItemCount() -1; x++){
            if (cmbPorte.getItemAt(x).toString().equals(_a.getPorte())){
                cmbPorte.setSelectedIndex(x);                
            }
        }        
        
        
    }//GEN-LAST:event_jTableAnimalMouseReleased

    private void jButton5ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton5ActionPerformed
        
        if (!txtCodigo.getText().equals("*") && !txtCodigo.getText().equals("")){        
            txtCodigoAnimal.setText("*");

            txtNomeAnimal.setText(null);
            txtDataNasciAnimal.setText(null);
            txtDataCadastroAnimal.setText(null);

            //posiciona a porte
            cmbPorte.setSelectedIndex(0);
            cmbEspecie.setSelectedIndex(0);
            cmbRaca.setSelectedIndex(0);
            cmbSexo.setSelectedIndex(0);

            this.limparResutladosBuscas(jTableAnimal);

            txtNomeAnimal.requestFocus();
        } else {
            JOptionPane.showMessageDialog(null, "Escolha um cliente primeiro.");
        }
    }//GEN-LAST:event_jButton5ActionPerformed

    private void jButton8ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton8ActionPerformed

        
        if (!txtCodigo.getText().equals("*") && !txtCodigo.getText().equals("")){
            Animal _a = new Animal();

            _a.setNomeAnimal(txtNomeAnimal.getText());
            _a.setPorte(cmbPorte.getSelectedItem().toString());
            _a.setEspecie(new EspecieDAO().getEspecieByNome(cmbEspecie.getSelectedItem().toString()));
            _a.setRaca(new RacaDAO().getRacaByNome(cmbRaca.getSelectedItem().toString()));
            _a.setSexo(cmbSexo.getSelectedItem().toString());
            _a.setDataNasc(txtDataNasciAnimal.getText());
            if (txtCodigoAnimal.getText().equals("*")){
                _a.setCodigoAnimal(0);
            } else {
                _a.setCodigoAnimal(Integer.parseInt(txtCodigoAnimal.getText()));
            }

            AnimalDAO _aDAO = new AnimalDAO();
            boolean ret = _aDAO.salvarAnimal(Integer.parseInt(txtCodigo.getText()),_a);
            
            if (ret){
                JOptionPane.showMessageDialog(null, "Animal incluído com sucesso.");
            } else {
                JOptionPane.showMessageDialog(null, "Erro ao inserir o animal.");
            }
            
        } else {
            JOptionPane.showMessageDialog(null, "Escolha um cliente primeiro.");
        }
        
    }//GEN-LAST:event_jButton8ActionPerformed

    /**
     * @param args the command line arguments
     */
    public static void main(String args[]) {
        /* Set the Nimbus look and feel */
        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
         */
        try {
            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
                if ("Nimbus".equals(info.getName())) {
                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (ClassNotFoundException ex) {
            java.util.logging.Logger.getLogger(JFrameCliente.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            java.util.logging.Logger.getLogger(JFrameCliente.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            java.util.logging.Logger.getLogger(JFrameCliente.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
            java.util.logging.Logger.getLogger(JFrameCliente.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        }
        //</editor-fold>

        /* Create and display the form */
        java.awt.EventQueue.invokeLater(new Runnable() {

            public void run() {
                new JFrameCliente().setVisible(true);
            }
        });
    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton btnBuscar;
    private javax.swing.JToggleButton btnBuscarAnimal;
    private javax.swing.JButton btnExcluir;
    private javax.swing.JButton btnNovo;
    private javax.swing.JButton btnSalvar;
    private javax.swing.JComboBox cmbEspecie;
    private javax.swing.JComboBox cmbPorte;
    private javax.swing.JComboBox cmbRaca;
    private javax.swing.JComboBox cmbSexo;
    private javax.swing.JButton jButton5;
    private javax.swing.JButton jButton7;
    private javax.swing.JButton jButton8;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel13;
    private javax.swing.JLabel jLabel18;
    private javax.swing.JLabel jLabel19;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JPanel jPanelDadosAnimal;
    private javax.swing.JScrollPane jScrollPaneAnimal;
    private javax.swing.JScrollPane jScrollPaneResultado;
    private javax.swing.JScrollPane jScrollPaneResultado1;
    private javax.swing.JTable jTableAnimal;
    private javax.swing.JTable jTableTelefone;
    private javax.swing.JToolBar jToolBarCliente;
    private javax.swing.JLabel lblCep;
    private javax.swing.JLabel lblCidade;
    private javax.swing.JLabel lblCodigo;
    private javax.swing.JLabel lblCodigo1;
    private javax.swing.JLabel lblCpf;
    private javax.swing.JLabel lblCpf1;
    private javax.swing.JLabel lblDataCadastroAnimal;
    private javax.swing.JLabel lblDataNasc;
    private javax.swing.JLabel lblDtCadastro1;
    private javax.swing.JLabel lblDtNascimento;
    private javax.swing.JLabel lblEmail;
    private javax.swing.JLabel lblEspecie;
    private javax.swing.JLabel lblEstado;
    private javax.swing.JLabel lblNome;
    private javax.swing.JLabel lblNome1;
    private javax.swing.JLabel lblPesquisa;
    private javax.swing.JLabel lblPesquisarPor;
    private javax.swing.JLabel lblPorte;
    private javax.swing.JLabel lblRaca;
    private javax.swing.JLabel lblResulPesq;
    private javax.swing.JLabel lblResultado;
    private javax.swing.JLabel lblSexo;
    private javax.swing.JPanel pnlAnimal;
    private javax.swing.JPanel pnlBusca;
    private javax.swing.JPanel pnlCadastroAnimal;
    private javax.swing.JPanel pnlCliente;
    private javax.swing.JPanel pnlDados;
    private javax.swing.JPanel pnlEndereço;
    private javax.swing.JPanel pnlTelefone;
    private javax.swing.JTable tbeResultadoCliente;
    private javax.swing.JToolBar tbrCliente;
    private javax.swing.JTextField txtCep;
    private javax.swing.JTextField txtCidade;
    private javax.swing.JTextField txtCodigo;
    private javax.swing.JTextField txtCodigoAnimal;
    private javax.swing.JFormattedTextField txtCpf;
    private javax.swing.JTextField txtDataCadastroAnimal;
    private javax.swing.JTextField txtDataNasciAnimal;
    private javax.swing.JFormattedTextField txtDtCadastro;
    private javax.swing.JFormattedTextField txtDtNascimento;
    private javax.swing.JFormattedTextField txtEmail;
    private javax.swing.JTextField txtEndereco;
    private javax.swing.JTextField txtEstado;
    private javax.swing.JTextField txtNome;
    private javax.swing.JTextField txtNomeAnimal;
    private javax.swing.JTextField txtPesquisaAnimal;
    private javax.swing.JTextField txtPesquisaCliente;
    private javax.swing.JFormattedTextField txtRg;
    // End of variables declaration//GEN-END:variables
}